Component({
  behaviors: ['wx://form-field-group'],
  properties: {
    type: {
      type: String,
      value: ''
    },
    name: {
      type: String,
      value: ''
    },
    fields: {
      type: Object,
      value: {}
    },
    bindData: {
      type: Object,
      value: {}
    },
    fileQty: {
      type: Number,
      value: null,
    }
  },
  methods: {
    changePicker(e) {
      this.triggerEvent("changePicker", e.detail);
    },
    getLileList(e) {
      this.data.fields[this.data.name].fileImageList = e.detail.fileList
      if (e.detail.errorMessage) {
        this.data.fields[this.data.name].errorMessage = this.data.fields[this.data.name].label + e.detail.errorMessage
      } else {
        this.data.fields[this.data.name].errorMessage = e.detail.errorMessage
      }

      this.triggerEvent("fuzhiFile", this.data.fields);
    }

  }
})